package com.xiangsai;

import lombok.Data;
import lombok.ToString;

/**
 * @program: paxos-java-demo
 * @description 决策者对提议者的准备提案的的答复
 * @author: wzx
 * @create: 2021-07-09 16:16
 **/
@Data
@ToString
public class PrepareResult {
    private boolean isPromised; //是否承诺
    //决策者状态
    private AcceptorStatus acceptorStatus = AcceptorStatus.NONE;
    //决策者返回的提案
    private Proposal proposal;

    //返回是否承诺
    public boolean isPromised() {
        return this.isPromised;
    }
}
